package com.wgh.search.entity;

import lombok.Data;
import org.springframework.data.elasticsearch.annotations.Field;
import org.springframework.data.elasticsearch.annotations.FieldType;

import java.math.BigDecimal;
import java.util.Map;

/**
 * SKU文档实体类 - 用于Elasticsearch
 */
@Data
public class SkuDoc {
    
    @Field(type = FieldType.Integer)
    private Long id;
    
    @Field(type = FieldType.Integer)
    private Long productId;
    
    @Field(type = FieldType.Double)
    private BigDecimal price;
    
    @Field(type = FieldType.Integer)
    private Integer stock;
    
    @Field(type = FieldType.Integer)
    private Integer sales;
    
    @Field(type = FieldType.Keyword)
    private String image;
    
    @Field(type = FieldType.Object)
    private Map<String, String> attributes;
    
    @Field(type = FieldType.Keyword)
    private String attributesText;
    
    @Field(type = FieldType.Integer)
    private Integer status;
}